﻿using APP.DTO.ApplicationInfo;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace APP.DTO.Const
{
    public class MiddlewareMsgConst
    {

        /// <summary>
        /// True:启动成功 False:启动失败
        /// </summary>
        public static bool IsStartUp { get; set; }


        public static readonly List<string> NoStateMethodList = new List<string> {  "LoginUser" };

        /// <summary>
        /// 非登录状态 允许调用的方法
        /// </summary>
        public static readonly List<string> NoSecurityMethodList = new List<string> {  "LoginUser"};

      /// <summary>
      /// 在线人数
      /// </summary>
        public static int LineNumberCount = -1;
        public static int MaxUsersCount = -1;
        /// <summary>
        /// 单位:分钟
        /// </summary>
        public static int NoneOperationTimeSpan = 20;


        public readonly static List<string> MsgList = new List<string> { "用户未登录" };
        public readonly static List<string> LoginMsgList = new List<string> { "用户数量超出" };




        #region 控制在线数相关描述
        /// <summary>
        /// 返回的描述信息的前缀带【退出登录_】则需要客户端需要重新启动
        /// </summary>
        public static string Restprefix = "退出登录_";

        public static string MaxLineMsg = Restprefix + "当前在线用户总数,已达到最大在线数总和限制";
        public static string BeatchMaxLineMsg = Restprefix + "当前批次在线用户数,已达到当前批次在线数限制";
        public static string ExitMsg = Restprefix + "账号已主动退出";
        public static string ForceExitMsg = Restprefix + "账号强制退出";
        public static string TimeOutOperation = Restprefix + "长时间无操作,请重新登录";

        public static string OtherMsg = Restprefix + "请求失效,请重新登录";

        public static string MaxAccountMsg = Restprefix + "账号不能超出最大数量";
        /// <summary>
        /// 加密狗返回用户未登录 1.账号多次登录被顶掉 2.账号没有登录
        /// </summary>
        public static string NoLogin = Restprefix + "账号重复登录或未登录,请重新登录";

        public static string ExceptionLoginId = "账号信息异常";

        public static string ExceptionLoginIdNoLinceKey = "账号使用的许可证号未授权";
        #endregion
    }
}
